#define MSFEEDBACK_C
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <libmscommon/mscommon.h>
#include <libmscommon/mstime.h>
#include <libmslog/mslog.h>
#include "msemail.h"
#include "msfeedback.h"

#define FLAG 		"FEEDBACK"
//Waring :Before modify this api, please concat su.gao
///usr/bin/sendemail -s  smtp.163.com  -f smartavs@163.com  -t  mscore_test@163.com   -u  smartavs   -xu  smartavs   -xp 12315sugao   -o   tls=auto   -m   loginId:5241
void msfeedback_api_run(char *pcontent,char *ologo,char *configfile)
{
	MSEMAILContxt email_ctt;
	memset(&email_ctt,0,sizeof(MSEMAILContxt));
	ms_strcpy(email_ctt.dns, "smtp.163.com");
	ms_strcpy(email_ctt.from, "smartavs@163.com");
	ms_strcpy(email_ctt.to, "mscore_test@163.com");
	ms_s08 strCurDTime[64]={0};
	ms_sprintfs(email_ctt.theme,"[%s]%s %s information",ologo,mstime_api_curDTime(mstime_fmt_datetime,strCurDTime),"msavskit");
	ms_strcpy(email_ctt.user, "smartavs");
	ms_strcpy(email_ctt.passwd, "CHSZJXZQJEYRZPVF");
	ms_strcpy(email_ctt.attach, configfile);
	ms_strcpy(email_ctt.content,pcontent);	
	msemail_api_send( &email_ctt);
}
#undef MSFEEDBACK_C

